Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Token Search Results #1056

Merged
merged 84 commits into from
Nov 6, 2024
Merged

Add Token Search Results #1056

merged 84 commits into from
Nov 6, 2024

Conversation

achowdhry-ripple
Copy link
Collaborator

@achowdhry-ripple achowdhry-ripple commented Oct 8, 2024

High Level Overview of Change

In order to improve the usability of the search bar inside of Explorer, matching tokens will now auto-populate as a user is typing. The results are clickable and redirect to the respective token page. The data is pulled from XRPLMeta and cached inside of the Explorer backend to display an open sourced list of tokens and relevant statistics.

Backend changes implement serverside caching of tokens data from XRPL Meta, and exposes an API from the explorer backend for search result querying. This is less expensive than the previous approach of websockets (which remain open for the duration of a user session) and are susceptible to rate limits on XRPLMeta's public node infrastructure. This also offers resilience in the case that the public XRPLMeta node has downtime.

Desktop:
Screenshot 2024-11-05 at 4 36 33 PM

Mobile:
Screenshot 2024-11-05 at 4 37 26 PM

Context of Change

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Refactor (non-breaking change that only restructures code)
  • Tests (You added tests for code that already exists, or your new feature included in this PR)
  • Documentation Updates
  • Translation Updates
  • Release

TypeScript/Hooks Update

  • Updated files to React Hooks
  • Updated files to TypeScript

Before / After

Test Plan

@ckniffen
Copy link
Collaborator

ckniffen commented Oct 8, 2024

Make sure the search doesnt happen on non mainet explorers. The xrpl meta url should also be an environment variable.

</div>
</div>
</div>
<div className="result-issuer-line">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I meant the bottom two lines

@achowdhry-ripple achowdhry-ripple merged commit 5a93a6d into staging Nov 6, 2024
4 checks passed
@achowdhry-ripple achowdhry-ripple deleted the search-results branch November 6, 2024 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants